
import 'package:flutter_data_json_app/base/base_request.dart';
import 'package:flutter_data_json_app/entity/deliver_details.dart';
import 'package:flutter_data_json_app/entity/deliver_list.dart';
import 'package:flutter_data_json_app/entity/request_bean.dart';

Future<RequestBean<DeliverList>> apiGetDeliverListByDriverLoc(
    int current,    //当前页
    int size,   //页显示数量
    Map cond,   //查询条件  {"longitude":111.2, "latitude":33}
    )async{
  Map data = {
    "current":current,
    "size":size,
    "cond": cond
  };
  return postWithBean(DeliverList(null),'deliverService.getDeliverListByDriverLoc',data);
}


Future<RequestBean<DeliverDetails>> apiOrderDetails(
    ///订单ID
    int deliverId,
    ///查询途径(1:货主版订单详情页 2:司机版订单详情页)
    int channelType
    )async{
  Map data = {"deliverId":deliverId,"channelType":channelType};
  return postWithBean<DeliverDetails>(DeliverDetails(null),'deliverService.selectById',data);
}